package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.EnzymeActivityMapper;
import com.ruoyi.system.domain.EnzymeActivity;
import com.ruoyi.system.service.IEnzymeActivityService;
import com.ruoyi.common.core.text.Convert;

/**
 * 酶活性Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-03-20
 */
@Service
public class EnzymeActivityServiceImpl implements IEnzymeActivityService 
{
    @Autowired
    private EnzymeActivityMapper enzymeActivityMapper;

    /**
     * 查询酶活性
     * 
     * @param id 酶活性主键
     * @return 酶活性
     */
    @Override
    public EnzymeActivity selectEnzymeActivityById(Long id)
    {
        return enzymeActivityMapper.selectEnzymeActivityById(id);
    }

    /**
     * 查询酶活性列表
     * 
     * @param enzymeActivity 酶活性
     * @return 酶活性
     */
    @Override
    public List<EnzymeActivity> selectEnzymeActivityList(EnzymeActivity enzymeActivity)
    {
        return enzymeActivityMapper.selectEnzymeActivityList(enzymeActivity);
    }

    /**
     * 新增酶活性
     * 
     * @param enzymeActivity 酶活性
     * @return 结果
     */
    @Override
    public int insertEnzymeActivity(EnzymeActivity enzymeActivity)
    {
        return enzymeActivityMapper.insertEnzymeActivity(enzymeActivity);
    }

    /**
     * 修改酶活性
     * 
     * @param enzymeActivity 酶活性
     * @return 结果
     */
    @Override
    public int updateEnzymeActivity(EnzymeActivity enzymeActivity)
    {
        return enzymeActivityMapper.updateEnzymeActivity(enzymeActivity);
    }

    /**
     * 批量删除酶活性
     * 
     * @param ids 需要删除的酶活性主键
     * @return 结果
     */
    @Override
    public int deleteEnzymeActivityByIds(String ids)
    {
        return enzymeActivityMapper.deleteEnzymeActivityByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除酶活性信息
     * 
     * @param id 酶活性主键
     * @return 结果
     */
    @Override
    public int deleteEnzymeActivityById(Long id)
    {
        return enzymeActivityMapper.deleteEnzymeActivityById(id);
    }
}
